const { buildModule } = require("@nomicfoundation/hardhat-ignition/modules");
const { ACLManagerModule } = require("./ACLManager");
const { DNPWithFakesModule } = require("./DeltaNeutralPortfolio");
const { TestTokensModule } = require("./Fakes");

const PoolModule = buildModule("Pool", m => {
  const { ACLManager } = m.useModule(ACLManagerModule);
  const { DNP } = m.useModule(DNPWithFakesModule);
  const { tokenA } = m.useModule(TestTokensModule);

  const pool = m.contract("Pool", [ACLManager, tokenA, DNP]);

  return { pool };
});

module.exports = { PoolModule };
